package com.ruoyi.project.beautyflower.loanSetting.service;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.beautyflower.loanSetting.mapper.LoanSettingMapper;
import com.ruoyi.project.beautyflower.loanSetting.domain.LoanSetting;
import com.ruoyi.project.beautyflower.loanSetting.service.ILoanSettingService;
import com.ruoyi.common.support.Convert;

/**
 * 贷款设置 服务层实现
 * 
 * @author lxs
 * @date 2018-10-09
 */
@Service
public class LoanSettingServiceImpl implements ILoanSettingService 
{
	@Autowired
	private LoanSettingMapper loanSettingMapper;

	/**
     * 查询贷款设置信息
     * 
     * @param id 贷款设置ID
     * @return 贷款设置信息
     */
    @Override
	public LoanSetting selectLoanSettingById(Integer id)
	{
	    return loanSettingMapper.selectLoanSettingById(id);
	}
	
	/**
     * 查询贷款设置列表
     * 
     * @param loanSetting 贷款设置信息
     * @return 贷款设置集合
     */
	@Override
	public List<LoanSetting> selectLoanSettingList(LoanSetting loanSetting)
	{
	    return loanSettingMapper.selectLoanSettingList(loanSetting);
	}
	
    /**
     * 新增贷款设置
     * 
     * @param loanSetting 贷款设置信息
     * @return 结果
     */
	@Override
	public int insertLoanSetting(LoanSetting loanSetting)
	{
	    return loanSettingMapper.insertLoanSetting(loanSetting);
	}
	
	/**
     * 修改贷款设置
     * 
     * @param loanSetting 贷款设置信息
     * @return 结果
     */
	@Override
	public int updateLoanSetting(LoanSetting loanSetting)
	{
	    return loanSettingMapper.updateLoanSetting(loanSetting);
	}

	/**
     * 删除贷款设置对象
     * 
     * @param ids 需要删除的数据ID
     * @return 结果
     */
	@Override
	public int deleteLoanSettingByIds(String ids)
	{
		return loanSettingMapper.deleteLoanSettingByIds(Convert.toStrArray(ids));
	}
	
}
